package com.kitty.web.system.onlinemall.service.impl;

import com.kitty.web.core.Convert;
import com.kitty.web.domain.AnnualShopItem;
import com.kitty.web.mapper.AnnualShopItemMapper;
import com.kitty.web.system.onlinemall.service.IAnnualShopItemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;


/**
 * 周年卡Service业务层处理
 * 
 * @author soul
 * @date 2022-03-10
 */
@Service
public class AnnualShopItemServiceImpl implements IAnnualShopItemService
{
    @Autowired
    private AnnualShopItemMapper AnnualShopItemMapper;

    /**
     * 查询周年卡
     * 
     * @param id 周年卡ID
     * @return 周年卡
     */
    @Override
    public AnnualShopItem selectAnnualShopItemById(Long id)
    {
        return AnnualShopItemMapper.selectAnnualShopItemById(id);
    }

    /**
     * 查询周年卡列表
     * 
     * @param AnnualShopItem 周年卡
     * @return 周年卡
     */
    @Override
    public List<AnnualShopItem> selectAnnualShopItemList(AnnualShopItem AnnualShopItem)
    {
        return AnnualShopItemMapper.selectAnnualShopItemList(AnnualShopItem);
    }

    /**
     * 新增周年卡
     * 
     * @param AnnualShopItem 周年卡
     * @return 结果
     */
    @Override
    public int insertAnnualShopItem(AnnualShopItem AnnualShopItem)
    {
        return AnnualShopItemMapper.insertAnnualShopItem(AnnualShopItem);
    }

    /**
     * 修改周年卡
     * 
     * @param AnnualShopItem 周年卡
     * @return 结果
     */
    @Override
    public int updateAnnualShopItem(AnnualShopItem AnnualShopItem)
    {
        return AnnualShopItemMapper.updateAnnualShopItem(AnnualShopItem);
    }

    /**
     * 删除周年卡对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteAnnualShopItemByIds(String ids)
    {
        return AnnualShopItemMapper.deleteAnnualShopItemByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除周年卡信息
     * 
     * @param id 周年卡ID
     * @return 结果
     */
    @Override
    public int deleteAnnualShopItemById(Long id)
    {
        return AnnualShopItemMapper.deleteAnnualShopItemById(id);
    }
}
